<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
		<link href="<s:url value="/css/style.css"/>" rel="stylesheet"
			type="text/css" />
		<link href="<s:url value="/css/jquery.css"/>" rel="stylesheet"
			type="text/css" />
		<script type="text/javascript" src="<s:url value="/js/jquery.js"/>"></script>
		<script type="text/javascript" src="<s:url value="/js/jquery-ui.js"/>"></script>
		<script type="text/javascript" src="<s:url value="/js/common.js"/>"></script>
		<script type="text/javascript"
			src="<s:url value="/js/jquery.validate.js"/>"></script>
		<script type="text/javascript">
			function doSubmit() {
				if (window.confirm('Save modify?')) {
					// here is validate form .
					$('#editForm').submit();
				}
			}
			function goBack() {
				location.href = '<s:url value="/clt/CorpCC/list"/>';
			}
			$( function() {
				$('#editForm').validate();
				$('#opptTime').datepicker( {
					dateFormat :'yy-mm-dd'
				});
				$('#initialVisitTime').datepicker({dateFormat:'yy-mm-dd'});
				if ($.trim($('#result').text()) != '') {
					popupDiv('pop-div');
				}
			});
		</script>
		<title><s:text name="system.title" /></title>
	</head>
	<body>
		<s:include value="/common/up.jsp"></s:include>
		<table width="100%" border="0" cellspacing="0" cellpadding="0">
			<tr>
				<td class="box">
					<table width="100%" border="0" cellspacing="0" cellpadding="0">
						<tr>
							<td id="tag-over">
								<span id="tag-over">Company</span>
							</td>
							<td class="tab3-line" width="90%">
								&nbsp;
							</td>
						</tr>
					</table>
					<s:form action="Company/save" namespace="/data" method="post"
						id="editForm" name="editForm">
						<s:hidden name="id"></s:hidden>
						<table width="100%" border="0" cellpadding="3" cellspacing="1"
							class="margin">
							<tr>
								<td align="right" width="50%" class="tablecolour5">
									Name
									<font color="red">*</font>:
								</td>
								<td width="50%" class="tablecolour5">
									<s:textfield name="name" cssClass="input2 required" size="24" />
								</td>
							</tr>
							<tr>
								<td align="right" class="tablecolour5">
									Telephone
									<font color="red">*</font>:
								</td>
								<td class="tablecolour5">
									<s:textfield name="telephone" cssClass="input2 required"
										size="24" />
								</td>
							</tr>
							<tr>
								<td align="right" class="tablecolour5">
									Fax:
								</td>
								<td class="tablecolour5">
									<s:textfield name="fax" cssClass="input2" size="24" />
								</td>
							</tr>
							<tr>
								<td align="right" class="tablecolour5">
									Contactor:
								</td>
								<td class="tablecolour5">
									<s:textfield name="contactor" cssClass="input2" size="24" />
								</td>
							</tr>
							<tr>
								<td align="right" class="tablecolour5">
									E-Mail:
								</td>
								<td class="tablecolour5">
									<s:textfield name="email" cssClass="input2" size="24" />
								</td>
							</tr>
							<tr>
								<td align="right" class="tablecolour5">
									Address:
								</td>
								<td class="tablecolour5">
									<s:textfield name="address" cssClass="input2" size="24" />
								</td>
							</tr>
							<tr>
								<td align="right" class="tablecolour5">
									Post Code:
								</td>
								<td class="tablecolour5">
									<s:textfield name="postCode" cssClass="input2" size="24" />
								</td>
							</tr>
							<tr>
								<td align="right" class="tablecolour5">
									Initial Visit:
								</td>
								<td class="tablecolour5">
									<s:date name="initialVisitTime" format="yyyy-MM-dd"
										var="initialVisitTimefmt" />
									<s:textfield value="%{initialVisitTimefmt}"
										name="initialVisitTime" cssClass="input2" size="24"
										id="initialVisitTime" />
								</td>
							</tr>
							<tr>
								<td align="right" class="tablecolour5">
									Oppt Time:
								</td>
								<td class="tablecolour5">
									<s:date name="opptTime" format="yyyy-MM-dd" var="opptTimefmt" />
									<s:textfield value="%{opptTimefmt}" name="opptTime"
										cssClass="input2" size="24" id="opptTime" />
								</td>
							</tr>
							<tr>
								<td align="right" class="tablecolour5">
									Stage:
								</td>
								<td class="tablecolour5">
									<s:select name="stage" listKey="name()"
										list="@com.ef.constant.EStageType@values()" />
								</td>
							</tr>
							<tr>
								<td align="center" colspan="2" height="50" class="tablecolour5">
									<input name="reset" type="reset" class="btn1" value="Reset" />
									<input type="button" class="btn1" value="Save"
										onclick="doSubmit();" />
									<input name="goback" type="button" class="btn1" value="Go Back"
										onclick="goBack()" />
								</td>
							</tr>
						</table>
					</s:form>
				</td>
			</tr>
		</table>
		<s:include value="/common/down.jsp"></s:include>
		<div id='pop-div' style="width: 300px;" class="pop-box">
			<s:include value="/common/confirm.jsp"></s:include>
		</div>
	</body>
</html>